Add .claude/settings.json with auto permission mode#513
Conversation
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Greptile SummaryThis PR adds a Key points:
Confidence Score: 4/5Safe to merge with minor consideration — the setting works as intended, but silently affects all contributors. The change is a single, syntactically correct JSON file. .claude/settings.json — consider documenting the rationale or moving to settings.local.json for per-contributor opt-in.
|
| Filename | Overview |
|---|---|
| .claude/settings.json | New file setting Claude Code's default permission mode to auto for all repo contributors; safe but silently overrides each contributor's personal permission preference. |
Flowchart
%%{init: {'theme': 'neutral'}}%%
flowchart TD
A[Contributor clones repo] --> B[Opens Claude Code in repo]
B --> C{Reads .claude/settings.json}
C --> D[defaultMode: auto applied]
D --> E[Tool call requested by Claude]
E --> F{Auto-mode classifier\nevaluates action}
F -->|Safe| G[Action runs automatically\nno user prompt]
F -->|Risky| H[Action blocked\nClaude tries alternative]
G --> I[Contributor may not realize\nauto mode is active]
Reviews (1): Last reviewed commit: "Add .claude/settings.json with auto perm..." | Re-trigger Greptile
| @@ -0,0 +1,5 @@ | |||
| { | |||
| "permissions": { | |||
| "defaultMode": "auto" | |||
There was a problem hiding this comment.
Auto mode applied to all contributors without explicit opt-in
Setting defaultMode: "auto" in the shared .claude/settings.json means every contributor who uses Claude Code in this repo will be placed in auto permission mode automatically, regardless of their personal preference. Auto mode uses a classifier to decide whether to proceed with actions without user confirmation — while safer than --dangerously-skip-permissions, it still bypasses interactive approval for tool calls.
Anthropic's own documentation notes that "a checked-in repo could otherwise inject its own allow rules" as the reason why autoMode classifier configuration is excluded from shared project settings. The defaultMode key is still honoured from shared settings, however.
Consider whether this should live in .claude/settings.local.json (which should be gitignored) so each contributor consciously opts in, rather than inheriting it silently from the repo. Alternatively, document the rationale in the PR/README so contributors are aware.
Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!
Summary
.claude/settings.jsonto set the default Claude Code permission mode toautofor this repo.Test plan
automode when working in this repo.🤖 Generated with Claude Code